{if $admin_request eq 'browse_users'}
<a href="#" id="trigger-help">Trigger-help</a>
<a href="#" id="back-button">Back Button</a>

<div id="helpsection">
help section/tips - hidden
</div>

<div id="search-records">
</div>

<div id="browse-records">
<table id="table-{$admin_request}" class="display datatable ui-helper-hidden">
<thead>
<tr>
            <th>
                {$lang.$base_request.id}a
            </th>
            <th>
                {$lang.$base_request.user_fullname}a
            </th>
            <th>
                {$lang.$base_request.username}b
            </th>
            <th>
                {$lang.$base_request.user_level}x
            </th>
            <th>
                {$lang.$base_request.createtime}x
            </th>
            <th>
                {$lang.$base_request.status}x
            </th>                              
            <th>
                {$lang.actions}
            </th>
            
        </tr>
        </thead>
        
 {foreach $pv.data.list as $item}
        <tr class="elements" bgcolor="">
            <td>
                {$item.id}
            </td>
            <td>
                {$item.user_fullname}
            </td>
            <td>
                {$item.username}
            </td>
            <td>
                {$pv.items.arr.user_level[$item.user_level]}
            </td>
            <td>
                {$item.createtime|date_format:$config.sdate_format}
            </td>
            <td>
                {if $item.status eq "1"}Active{else}Inactive{/if}
            </td>                          
            <td>
                <a href="#" class="edit-input tk-trigger" data-id="{$item.id}" data-action="edit"></a>

                <a href="#" class="delete-input tk-trigger" data-id="{$item.id}" data-action="delete"></a>

                <a href="#" class="tk-trigger{if $item.status eq "0"} inactive-input{/if}{if $item.status eq "1"} active-input{/if}" data-id="{$item.id}" data-action="toggle" data-value="{$item.status}"></a> 
            </td>
            
        </tr> {/foreach}

</table>

</div>

<div id="edit-record" class="ui-helper-hidden">

</div>

<div id="navigation">

</div>

{capture "$admin_request"}

loadJS(_templatePath + 'js_ondemand/jquery.dataTables.js',function(){ldelim}

oSettings = {ldelim}
    "bJQueryUI": true,
    "sPaginationType": "full_numbers",
    "aoColumns": [
            null,
            null,
            null,
            null,
            null,
            null,
            {ldelim} "bSortable": false {rdelim}
        ]    
{rdelim};
oTable = $('#table-{$admin_request}').dataTable(oSettings).removeClass('ui-helper-hidden');


{rdelim});

{/capture}

{/if}

{if $admin_request eq 'add_user'}


{/if}


{if $admin_request eq 'edit'}

@TODO

{/if}